home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Interactive Reference Guide
/
C-C++ Interactive Reference Guide.iso
/
c_ref
/
csource4
/
223_01
/
rename.c
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
C/C++ Source or Header
|
1979-12-31
|
512 b
|
21 lines
/*
** rename(old,new) char *old, *new; by F.A.Scacchitti 9/11/84
*/
#define NOCCARGC
#include <stdio.h>
static int fcbloc;
rename(old,new) char *old, *new; {
if ((fcbloc = grabio()) == NULL) return(ERR);
fcb(fcbloc, old);
fcb(fcbloc + 16, new);
freeio(fcbloc);
if(bdos(23,fcbloc) >= 0) return(NULL);
return(ERR);
}